package com.hb.core.pojo.project.deal.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.hb.core.pojo.project.deal.dto.BidCandidateDTO;
import com.hb.core.pojo.project.deal.dto.BidCandidateSectionDTO;
import com.hb.core.pojo.project.deal.entity.BidCandidateSection;
import com.hb.core.pojo.project.section.dto.BidSectionDTO;
import com.hb.core.pojo.project.section.entity.BidSection;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * 中标候选人公示-标段对应Mapper
 *
 * @author Lix1ang
 * @date 2021-12-28 14:13:03
 */
@Mapper
public interface BidCandidateSectionMapper extends BaseMapper<BidCandidateSection> {

    /**
     * 获取未被关联的标段
     *
     * @param page
     * @param bidCandidateDTO
     * @return
     */
    Page<BidSection> pageSectionNotSelected(@Param("page") Page page, @Param("bidCandidate") BidCandidateDTO bidCandidateDTO);

    /**
     * 根据候选人公示Id查询关联的标段
     *
     * @param candidateId
     * @return
     */
    Page<BidCandidateSectionDTO> listSectionByCandidateId(@Param("page") Page page, @Param("candidateId") Long candidateId);
}
